{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# User's Guide, Chapter 13: More Music21Object Attributes and Properties\n",
    "\n",
    "At this point you know how to find a `Music21Object`, how to name them and group them (with `.id` and `.groups`) and how to position them in Streams (with `.offset`, `.priority`, `.classSortOrder` and the `.activeSite`). This section gets first into some more advanced things that Music21Objects have, then some more fun things."
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### Sites and the storing of elements\n",
    "\n",
    "All `Music21Objects` (i.e., elements) have a `.sites` property which is a :class:`~music21.sites.Sites` object which holds information about all the places the `Music21Object` is stored in. At its simplest, it's something that can be iterated over:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 1,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "<music21.stream.Stream s1> 10.0\n",
      "<music21.stream.Stream s2> 20.0\n"
     ]
    }
   ],
   "source": [
    "from music21 import *\n",
    "\n",
    "n = note.Note()\n",
    "s1 = stream.Stream(id='s1')\n",
    "s2 = stream.Stream(id='s2')\n",
    "s1.insert(10, n)\n",
    "s2.insert(20, n)\n",
    "\n",
    "for s in n.sites:\n",
    "    print(s, s.elementOffset(n))"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Note that the order of the Streams in `.sites` is guaranteed to be the order in which the note was inserted into the site.\n",
    "\n",
    "There's a lot more that `.sites` can do, but primarily for developers.  We will get back to sites later."
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### Derivations\n",
    "\n",
    "We will talk about derivations more in a future chapter, butwe alluded to them in the Example in chapter 10, so let's say a few words about this advanced feature. A :class:`~music21.derivation.Derivation` object is a pointer to an object that this object is derived from in some way.  They've gone their separate ways to an extent, but may want to talk to each other later.  A `Music21Object` starts out with no useful Derivation:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<Derivation of <music21.note.Note C> from None>"
      ]
     },
     "execution_count": 2,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "c = note.Note(\"C4\")\n",
    "c.derivation"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "But we can create new notes from it and they're not totally connected, but show their connection through `.derivation`:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<music21.note.Note F>"
      ]
     },
     "execution_count": 3,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "f = c.transpose('P4')\n",
    "f"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<Derivation of <music21.note.Note F> from <music21.note.Note C> via 'transpose'>"
      ]
     },
     "execution_count": 4,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "f.derivation"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Now `c` has a life of its own from `f`.  We can add a sharp to C and the transpose relationship of F to C does not affect it:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "(<music21.note.Note C#>, <music21.note.Note F>)"
      ]
     },
     "execution_count": 5,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "c.pitch.accidental = pitch.Accidental('sharp')\n",
    "(c, f)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "But if `f` wants to do something to `c`, it can by changing itself and every element of its `.derivation.chain()`:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 6,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "('diamond', 'diamond')"
      ]
     },
     "execution_count": 6,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "f.notehead = 'diamond'\n",
    "for n in f.derivation.chain():\n",
    "    n.notehead = 'diamond'\n",
    "\n",
    "(f.notehead, c.notehead)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {
    "collapsed": true
   },
   "source": [
    "While `f` can search upwards in its `.derivation.chain()` and find `c`, `c` cannot find `f` in its derivation; it is a connection that is designed to be one-way only.\n",
    "\n",
    "Setting derivations can be done manually, but it's an advanced enough topic that we will get to it later."
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### Context attributes\n",
    "\n",
    "Several attributes of `Music21Objects` only work after the object has been placed inside a Stream that has certain features of their own.\n",
    "\n",
    "An easy one to understand is `.measureNumber` which finds the `.number` value of the measure that an object is placed in:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 7,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "7"
      ]
     },
     "execution_count": 7,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "n = note.Note('C')\n",
    "m = stream.Measure()\n",
    "m.number = 7\n",
    "m.append(n)\n",
    "n.measureNumber"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "This works even if a note is inside a voice inside a measure:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 8,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "7"
      ]
     },
     "execution_count": 8,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "v = stream.Voice()\n",
    "n2 = note.Note('D')\n",
    "v.append(n2)\n",
    "m.insert(0, v)\n",
    "n2.measureNumber"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Without a context, you'll get None"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 9,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "True"
      ]
     },
     "execution_count": 9,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "n3 = note.Note()\n",
    "n3.measureNumber is None"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "The second context attribute is, appropriately, called `.seconds`.  It requires a tempo.MetronomeMark() to be placed into the Stream before the object and will calculate how many seconds the object (note, etc.) lasts at that tempo:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 10,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "1.0 0.5\n"
     ]
    }
   ],
   "source": [
    "m.insert(0, tempo.MetronomeMark('Allegro', 120))\n",
    "print (n.quarterLength, n.seconds)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Unlike `.measureNumber` and the rest of the attributes we will see below, you can change `.seconds` to reflect exact timing you might have from audio or MIDI data."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 11,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "0.6"
      ]
     },
     "execution_count": 11,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "n.seconds = 0.6\n",
    "n.seconds"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "An object with no tempo information in its surrounding context returns an error for `.seconds`"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 12,
   "metadata": {
    "tags": [
     "nbval-raises-exception"
    ]
   },
   "outputs": [
    {
     "ename": "Music21ObjectException",
     "evalue": "this object does not have a TempoIndication in Sites",
     "output_type": "error",
     "traceback": [
      "\u001b[0;31m---------------------------------------------------------------------------\u001b[0m",
      "\u001b[0;31mMusic21ObjectException\u001b[0m                    Traceback (most recent call last)",
      "\u001b[0;32m<ipython-input-12-26031fc2df74>\u001b[0m in \u001b[0;36m<module>\u001b[0;34m\u001b[0m\n\u001b[1;32m      1\u001b[0m \u001b[0mn3\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mnote\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mNote\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m'E'\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m----> 2\u001b[0;31m \u001b[0mn3\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mseconds\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m",
      "\u001b[0;32m~/git/music21base/music21/base.py\u001b[0m in \u001b[0;36m_getSeconds\u001b[0;34m(self)\u001b[0m\n\u001b[1;32m   3437\u001b[0m         \u001b[0mti\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mgetContextByClass\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m'TempoIndication'\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m   3438\u001b[0m         \u001b[0;32mif\u001b[0m \u001b[0mti\u001b[0m \u001b[0;32mis\u001b[0m \u001b[0;32mNone\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m-> 3439\u001b[0;31m             \u001b[0;32mraise\u001b[0m \u001b[0mMusic21ObjectException\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m'this object does not have a TempoIndication in Sites'\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m   3440\u001b[0m         \u001b[0mmm\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mti\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mgetSoundingMetronomeMark\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m   3441\u001b[0m         \u001b[0;31m# once we have mm, simply pass in this duration\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n",
      "\u001b[0;31mMusic21ObjectException\u001b[0m: this object does not have a TempoIndication in Sites"
     ]
    }
   ],
   "source": [
    "n3 = note.Note('E')\n",
    "n3.seconds"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "So use `try...except...` to catch this:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 13,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "C 0.6\n",
      "D 0.5\n",
      "E No information\n"
     ]
    }
   ],
   "source": [
    "for el in (n, n2, n3):\n",
    "    seconds = \"No information\"\n",
    "    try:\n",
    "        seconds = el.seconds\n",
    "    except exceptions21.Music21Exception:\n",
    "        pass\n",
    "    print(el.step, seconds)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {
    "sphinx_links": {
     "any": true
    }
   },
   "source": [
    "The last three context attributes, `.beat`, `.beatStr` (beat string), and `.beatStrength`, all require :class:`~music21.meter.TimeSignature` contexts. Since they're the topic of :ref:`our next chapter<usersGuide_14_timeSignatures>` we'll put them off until then.\n",
    "\n",
    "Most `Music21Objects` such as `Notes` have many additional attributes, but these are all the ones that are common to every object that can go in a `Stream` (after all, what would `.step` mean for a :class:`~music21.tempo.MetronomeMark`?)"
   ]
  },
  {
   "cell_type": "raw",
   "metadata": {},
   "source": [
    ".. note::\n",
    "\n",
    "   You may find other attributes on your base.Music21Object, especially if you are running\n",
    "   an older version of `music21`. They are all deprecated most have been removed in\n",
    "   v.3 or v.6; programmers are advised to stick to the safe list of attributes described here."
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Methods on `Music21Objects`\n",
    "\n",
    "Attributes and properties are aspects of an object that are lightweight and have no configuration options, so they are accessed without `()`. Methods tend to do more work and have more options, so they will always be called with `()` signs.\n",
    "\n",
    "Unlike attributes, where we have documented all of them, only a subset of the methods on `Music21Objects` are listed below.  All of them can be found in the documentation to :class:`~music21.base.Music21Object`, but many of them have obscure uses and might be moved later to not clutter up what is really important!  And those are..."
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### .getOffsetBySite and .setOffsetBySite\n",
    "\n",
    "These methods work as the `.offset` attribute but can work on any site where the object is a part of."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 14,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "10.0"
      ]
     },
     "execution_count": 14,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "n = note.Note()\n",
    "s1 = stream.Stream(id=\"s1\")\n",
    "s1.insert(10, n)\n",
    "s2 = stream.Stream(id=\"s2\")\n",
    "s2.insert(20, n)\n",
    "n.getOffsetBySite(s1)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 15,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "15.0"
      ]
     },
     "execution_count": 15,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "n.setOffsetBySite(s1, 15.0)\n",
    "n.getOffsetBySite(s1)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "There is one extra possible attribute on `.getOffsetBySite`, \"stringReturns=True\" which will say whether or not an element has a shifting offset.  Right barlines have one:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 16,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "4.0"
      ]
     },
     "execution_count": 16,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "s3 = stream.Measure()\n",
    "n3 = note.Note(type='whole')\n",
    "s3.append(n3)\n",
    "rb = bar.Barline()\n",
    "s3.rightBarline = rb\n",
    "rb.getOffsetBySite(s3)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 17,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "'highestTime'"
      ]
     },
     "execution_count": 17,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "rb.getOffsetBySite(s3, stringReturns=True)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "And in fact if we change the duration of `n3` the position of the barline will shift along with it:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 18,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "2.0"
      ]
     },
     "execution_count": 18,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "n3.duration.type = 'half'\n",
    "rb.getOffsetBySite(s3)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### getContextByClass()\n",
    "\n",
    "This is an extremely powerful tool -- you might not use it often, but be assured that `music21` is using it on your behalf all the time when sophisticated analysis is involved.  It finds the active element matching a certain class preceeding the element.  Let me demonstrate:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 19,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<music21.note.Note F#>"
      ]
     },
     "execution_count": 19,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "bach = corpus.parse('bwv66.6')\n",
    "lastNote = bach.recurse().getElementsByClass('Note')[-1]\n",
    "lastNote"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "What part is it in?"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 20,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<music21.stream.Part Bass>"
      ]
     },
     "execution_count": 20,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "lastNote.getContextByClass('Part')"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "What was the Key at that moment?"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 21,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<music21.key.Key of f# minor>"
      ]
     },
     "execution_count": 21,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "lastNote.getContextByClass('KeySignature')"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "What is the TimeSignature at that moment?"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 22,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<music21.meter.TimeSignature 4/4>"
      ]
     },
     "execution_count": 22,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "lastNote.getContextByClass('TimeSignature')"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Why is this such a sophisticated method? It knows about the differences in different types of Streams.  If the key signature changes in a different part then it doesn't affect the notes of the current part, but if it changes in a previous measure in the same part, then that matters.  Furthermore, the caching mechanism via something called `Timespans` is amazingly fast, so that running through an entire score getting the context for each object doesn't take long at all:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 23,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "<music21.meter.TimeSignature 6/8> 1\n",
      "<music21.meter.TimeSignature 2/4> 28\n",
      "<music21.meter.TimeSignature 6/8> 80\n",
      "<music21.meter.TimeSignature 3/4> 110\n"
     ]
    }
   ],
   "source": [
    "gloria = corpus.parse('luca/gloria')\n",
    "soprano = gloria.parts[0]\n",
    "\n",
    "lastTimeSignature = None\n",
    "for n in soprano.recurse().getElementsByClass('Note'):\n",
    "    thisTimeSignature = n.getContextByClass('TimeSignature')\n",
    "    if thisTimeSignature is not lastTimeSignature:\n",
    "        lastTimeSignature = thisTimeSignature\n",
    "        print(thisTimeSignature, n.measureNumber)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "As you might expect, the `.measureNumber` routine uses `.getContextByClass('Measure')` internally. What is also interesting is that `.getContextByClass` is smart enough to search out derivation chains to find what it is looking for.  For instance, this flat stream has only notes, no time signatures.  But it can still find each note's time signature ane measure number context."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 24,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "<music21.meter.TimeSignature 6/8> 1\n",
      "<music21.meter.TimeSignature 2/4> 28\n",
      "<music21.meter.TimeSignature 6/8> 80\n",
      "<music21.meter.TimeSignature 3/4> 110\n"
     ]
    }
   ],
   "source": [
    "lastTimeSignature = None\n",
    "for n in soprano.flat.notes:\n",
    "    thisTimeSignature = n.getContextByClass('TimeSignature')\n",
    "    if thisTimeSignature is not lastTimeSignature:\n",
    "        lastTimeSignature = thisTimeSignature\n",
    "        print(thisTimeSignature, n.measureNumber)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Internally `.getContextByClass` uses another `Music21Object` method called `.contextSites()` which is a generator that tells the system where to search next:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 25,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "ContextTuple(site=<music21.stream.Measure 9 offset=33.0>, offset=2.0, recurseType='elementsFirst')\n",
      "ContextTuple(site=<music21.stream.Part Bass>, offset=35.0, recurseType='flatten')\n",
      "ContextTuple(site=<music21.stream.Score 0x10d4ee4a8>, offset=35.0, recurseType='elementsOnly')\n"
     ]
    }
   ],
   "source": [
    "for cs in lastNote.contextSites():\n",
    "    print(cs)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "`.contextSites` returns a \"ContextTuple\" which is a lightweight namedtuple that has three attributes, `site`, `offset`, and `recurseType`.\n",
    "\n",
    "The first ContextTuple says that first the elements of `site`: Measure 9 should be searched, beginning at `offset` 2.0 and (because `recurseType` is elementsFirst) working backwards to the beginning of the measure, then if the matching context isn't found, the measure will be flattened (in case there are other voices in the measure) and anything from before offset 2.0 of that flattened stream will be searched.\n",
    "\n",
    "If that fails, then the Bass part as a whole will be searched, with all elements flattened, beginning at offset 35 and working backwards.  That way if the context is in another measure it will be found.\n",
    "\n",
    "Then if that fails, it will look at the score as a whole, beginning at offset 35 and working backwards, but only looking at things that are at the score level, not looking at elements within other parts. There may be scores where for instance, expressive markings appear at the Score level. This will find them.\n",
    "\n",
    "Related to `.getContextByClass()` is `.getAllContextsByClass()` which is a generator that returns each preceeding context."
   ]
  },
  {
   "cell_type": "raw",
   "metadata": {},
   "source": [
    ".. note::\n",
    "\n",
    "   Prior to v.3, `.getAllContextsByClass()` had a different purpose, so do not use it for\n",
    "   for this purpose. It was unreliable.\n",
    "   \n",
    "   Two known bugs that we hope to get fixed soon: if there are two or more\n",
    "   contexts at the same offset, `.getAllContextsByClass()` will skip over \n",
    "   all but one of them. Using `Music21Object` as a class list can create infinite loops."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 26,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "<music21.meter.TimeSignature 3/4> 110\n",
      "<music21.meter.TimeSignature 6/8> 80\n",
      "<music21.meter.TimeSignature 2/4> 28\n",
      "<music21.meter.TimeSignature 6/8> 1\n"
     ]
    }
   ],
   "source": [
    "lastGloriaNote = soprano.flat.notes[-1]\n",
    "\n",
    "for ts in lastGloriaNote.getAllContextsByClass('TimeSignature'):\n",
    "    print(ts, ts.measureNumber)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {
    "collapsed": true
   },
   "source": [
    "Similar to `.getContextByClass()` are the `.next(class)` and `.previous(class)` methods which move to the next or previous element of the same class at the same (or a higher) hierarchical level.  They're designed to be really easy to use, but so far, I've failed at achieving that.  Hopefully in the next few versions I'll be able to demonstrate in practice how these commands were designed to work.  For now, I'd suggest avoiding them.\n",
    "\n",
    "### Splitting methods\n",
    "\n",
    "`Music21` has three methods on `Music21Object`s for splitting them.  Eventually the plan is to unite them into a single `.split()` method, but we're not there yet.\n",
    "\n",
    "The three methods are:\n",
    "\n",
    "* `.splitAtQuarterLength` -- splits an object into two objects at the given quarter length\n",
    "* `.splitByQuarterLengths` -- splits an object into two or more objects according to a list of quarter lengths\n",
    "* `.splitAtDurations` -- takes an object with a complex duration (such as 5.0 quarters) and splits it into notatable units.\n",
    "\n",
    "These all work rather similarly.  Behind their seeming simplicity are a host of complex musical decisions that are being made.  Take this rather complex note (we're introducing `expressions` and `articulations` softly here, so that you don't need to wait for :ref:`Chapter 32<usersGuide_32_articulations>` to encounter them):"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 27,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAVYAAADMCAYAAAAoJYsSAAAACXBIWXMAAB7CAAAewgFu0HU+AAAaNUlEQVR4nO3debgcVZnH8e9NbkISErKQEAhLwhYEJGBkCTCBEEBQJAIKrlFgkAEUQUVhHFEUJPiggiC4gAMDKogoCC5AQFnCEoUMDIQAkhDA7CQBsph7s9z5462iqk/X0tVd1X277+/zPP1Ud9WpqtN902+qT53zHpCeaCvgKeB2YFiD6yIi0tS28JZTgS5gQwPrIiLSdKYCPwQGhNY9C6zBgmoXsNZbvw1wHXBEPSsoItJMDsCuRruAX3vrBoTW+Y83gTbgAe/1amDveldWRKS72wyYTWkA/TpwkLOuC1gCnOWsexVrgxUREc+llAfQTdhPfXf929hVqrt+BtC33hUXEemOxgPrKQ+UXQnr4x7/7Rx7X6zJ4LCi34SISHfRB3iGbMEz7fEl79gDgJe9dVfU5d2IiHQDF5FvUPW7Yx0NXEnQdLBDnd6PiEhDjQM6seB3FbCUygLnSq98UplVwEbv+Rn1ekMiIo32BBb4ZgK9gYlAB+mBdT7QC7i7grJ/wbpmiYi0vDZgMdbxf4/Q+n+nssAKMIjyLlrhx2pgP+A44KPAngW+HxGRbmErYNuI9T8gPbAOAc4B5iSUm0HQHOA/7vb2FRFpSbsC04A/Aw8DtwFfBLYD7qM8UD7mLVdg7azLgbuwwQFu2U5v+1nA7sAE4H5v2/X1eHMiIvV2Fhb8ngFuAn4O/A27wuzEgq0bLP/oLTcBFwL9vWO1A8ucshuxPqwAg7EAPougl4DaXUWkpRyLBcdTI7btil25Rv203+QtX4/Y7y9O2ene+qEEfVnDj83zeSsiIt3DEwRJVuLcS2kgXAqcSenNqzD3ivUib/2XKQ+q67BeBSISoi9Fc9sb+9kfZ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JlTsy4VxPemU60K8fEWlhbmD1H3OBvwIbQ+teJhgksi12A8rdLymw3uaVeSnvNyHSzHSV0fo6gU8AOwOHYf1UfTtj/VHBegNsjY24qtSr3nJ+bVUUaS0KrK3v08Atodf/Q9BPFaxrlW8tdlW7qsJjv+YsRQQF1p5gpvN6I6V39IdH7FNpYPWPo8AqEqLA2jPFdfrPaoG3/GdOxxNpCQqsUovF3nJhQ2sh0s0osEot/NFWixpaC5FuRoFVatEB/ISgd4CIoJFXUrszG10Bke5GV6ytp0/Ka3dd1H+uadt9k4CrgJPQvyURaWE7UTpyamJEmUWh7ec72zYDNoS2nxxznu0pHcV1bI31FhHplvYEbqY0sE7H5rBqx2YT+Iaz/SUs4coAbFqWq53ts7B8A4Occ01xyk0r7F2JiDTQJqLzBGwERmM5VqO2dwHnJWyLCpyDsJysfkKX/Yt7WyIiPUd/LLfA0EZXRKQ7+X/VMsERt/Ww8QAAAABJRU5ErkJggg==\n",
      "text/plain": [
       "<IPython.core.display.Image object>"
      ]
     },
     "metadata": {
      "image/png": {
       "height": 102,
       "width": 171
      }
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "n = note.Note('C#5')\n",
    "n.duration.type = 'whole'\n",
    "n.articulations = [articulations.Staccato(), articulations.Accent()]\n",
    "n.lyric = 'hi!'\n",
    "n.expressions = [expressions.Mordent(), expressions.Trill(), expressions.Fermata()]\n",
    "n.show()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Now let's split this note just before beat 4:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 28,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAZ4AAAC0CAYAAACkPErrAAAACXBIWXMAAB7CAAAewgFu0HU+AAAfP0lEQVR4nO3deZgcdZ3H8fdMJpOD3CSEhADhCnIFjNwsVwBBEQRcQNAsgsgqAgqKrCwIKgv4IKIgKJewgIqCgAEVueVGIYLc4QpHyEEOIAeZmcz0/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jvOv35ZST4UsExFJlQJP69iI0r/nc87zW87zGN+6YOBZAMzNoFwiIkUUeFpHWEaBN53nCc7zu751wa7UutsRkbpQ4GkdS0KWrXaeDwVedx5gc/h8PLCtAo+IiCQyhNLJ4P4HONZZfpxv260o7Vjw2XoWVkREWsNMwgeQ3kFxjrWjQ7aZVNeSiohIS9iJ0rue3wKDA9tdhqXEeR5LIjq/jmUUkX5OmYZbzxQsu0E3ltTzuZBtNgVew2sDmgLMrkvpRERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERERBrYGGBy3oUQEZH+YTrwHrAC2DznsoiISIs7CugBCs7jeWBIriVqbj8EzgQ+C2wAtOVbHBGRxvJ5oBcv6LiPc/MsVJObS/HvchFwM3A88LEcyyUikrvtgC5Kg07BWa6LZHXWBo4DbgTmU/q7nQvcAByD2tREpB8ZCbxOeNBxH7fmVrrWsiVwEvb7XELp7/l14CrgSCxoiYi0pIuIDzoFoA/YJq8Ctqh24BPAqcBfgGWU/t6fBy4BDgZG51NMEZF0bQJ0Uz7wFIDf51TG/qID2AU4A7gH61no//33Ak8BFwCfAoblU0wRkdpcQ/mAs9R57gEm5lPMfmscsAfwdeBS4AG8gNQDfCevgolI62rP8NgTsbaEKD3AhVg34PnYN/LjMiyPlFqMdUCYC7zre/Rif48x+RVNRCS5bxF9lzMX2Nm37Q3O8jfqXMb+Zj1sLNU1wCzgI4r/LvOxHnLHARujcUEi0mQeJjzovERpj6pv+NbvVMcytrrx2PipK4BXCa/mvA3rCbdlTmUUEUnFYGA1pRe6Nwhvx5nu2+andSpjKxoNHARcDDxH6e9/OXAn1nazLdlWtYqI1NW2lF70urGBpGE2oviOSCozBOuBdgHWIy2YGaIL+BtwFrArMDCfYoqIZO8LlAae78VsPzqw7TpZF7BFvEjx72018ARwHrAPyoMnIv3ICZR2Joi7CA4KbH941gVsES8Dz2CDdA8ARuRbHBGR8joyOu7wwM8/wnpQRQkGpS3SLU7L2jTvAoiIJJVV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ssCxV2ID30UkQr0CT/DOaveMziMSphN4htI2zZuATao4XjtwOPB6yDG/mUJ5RVpaWOAZimXTPRe4AfgedscSpQPrVHAFsEXMdot951m3xnKLJLUxsJTwBKAzsUAyOmb/NmBzLP/bKyHHKQA3o2laRMoKBp7dgdmU/kOtwjoi+O0IXELxYLu49PFPOtt0UV26epFa7YvNWByVFqcPeBn4M/al61fA74CHKf7iFPb4F5b5QETKCAYef++f+7Fvg+6yV/GmolgH+DBkv7jA445vmJ32mxBJIDgEII3HHDQ2TaRiwcDTBRzhW39MYP02vnVDsYmuKg08FzjbJM0YLJK2GdhdfBpB5ylUdSySSDDwHB5YPwBvnE4B+EzIMfx3PnGBx01Vf1VtRRZJxVbAE1QfcLqxdtAkOdwkBaqnbz1PBH7uBd72/Tw2ZJ9lFR7bPc5bSQslkoFnsXbKQ4DHE+z3EfblaQrW0WBV+kWTOEoH0T+sTOk4c53nd1I6nkitCsCtzmMSsDXW+21trKNAB1b9vBT7/L6IdctekUdhxSjwSBLzned3cy2FSLh30JeipqCqNknCncFxXq6lEJGmpsAjSXQBvwTezLsgItK8VNUmSX0t7wKISHPTHU/zC2aUDssw7V8W9mWj3HrXHsDFwGHosyMi0m9tSPHYhF1DtpnnW39aYN0gilOQfCniPOtSnAUhjczAIiLSZLYArqc48NwNbIfduUzGEoT618/GphAeik17fUlg/Sws39vwwLkODGx3XmbvSkREGpZ/tkT/oxebKOvRiPUF4Nsx68ICy3DgPWfdKmD77N6WiLSy/wO2vmn/GYL0GAAAAABJRU5ErkJggg==\n",
      "text/plain": [
       "<IPython.core.display.Image object>"
      ]
     },
     "metadata": {
      "image/png": {
       "height": 90,
       "width": 207
      }
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "splitTuple = n.splitAtQuarterLength(3.0)\n",
    "s = stream.Stream()\n",
    "s.append(splitTuple)\n",
    "s.show()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Notice the choices that `music21` made -- the two notes are tied, the lyrics are sung at the beginning, the accent and mordent appear at the beginning of the note while the staccato and fermata(!) appear on the second note, while trill mark gets put onto the first note only. This is part of the \"batteries included\" `music21` approach -- try to do something musically smart in most cases.  In fact, it's even a bit smarter -- the `splitTuple` knows that there's something called a TrillExtension spanner in it which should be put into the Stream:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 30,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "[<music21.expressions.TrillExtension <music21.note.Note C#><music21.note.Note C#>>]"
      ]
     },
     "execution_count": 30,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "splitTuple.spannerList"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 29,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAZ4AAADSCAYAAAB6kaasAAAACXBIWXMAAB7CAAAewgFu0HU+AAAgAElEQVR4nO3debgcVZnH8e9dsm9cthAwIZBAWCOGXWQIm8AoqwKKMgg6jiKgooyjIwqKoo8iAgMCgjDACIgCg44gyCIKiAKi7HvAkIQshKzcNT1/vFX26eqq6q7urqrb3b/P89TTfbu2t5fbb59TZwER8z5g/byDEBGR1jXRu50B/AhYkGMsIiLSBp4A1gAFb/lVvuGISLvozjsAycVYYFugy3nskZxiEZE205l3AJKLnShNOqDEIyIZUeJpT7uEPKbEIyKZUOJpTzsH/n4dWJRHICLSfpR42lOwxKPSjohkRomn/YwDtgk8lnbiGQlcBTwAzE15vyzPlfV+zRBj1vs1Q4xZ75d1jCIVvYdiE2p/OTjlc/7EOVcfcGCK+2V5rqz3a4YYs96vGWLMer+sYxSp6LOUJ54NUzzf6SHnWwm8q8J+99WwX5bnynq/Vn5ute6n16Rc1q/JecBZFbYR4VpKP1yvRGw3EdgN2AvYILBuMnAEcCywfcy5DgYGKf9AF4DFMfteGbFP3H4HA0MZnSvr/Vr5udW6n16Tclm/Jv/ubXN9xHqRf3ia0g/WTc669bAS0V8D2wxixfAJwKWUf7h/6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Gm4jvAPpr7Dm074TQ7Z5R6aRiohIS9iT8lLP9cDowHaXYPNuPIUNIroowxhFpA10VN5EWsjW2OgG/dhw6E+GbDMLm4dn0Nnn+UyiExEREREREREREREREREREREREREREREREREREREREREREREREREREREREZH0deUdgGRiQ+BmYHPg9znHIiIibWB/bP6dV/IORESkM+8ApGGOBy4Axoas6wjcTgF+DByQQVwiItKCdscmbisAN4asP8BbNw9LPnd7f68G3plNiCIi0ipGYdNUu1NafzWwjZt4Tg5s+yqwcUaxiohIC/g2pYmkAKwDDne28RPPCqyUE9z+D8DI7EIWEZFmNQcYoDyRFIBVwA7edgdEbOMuPwkcexesSm7fVJ+BiIg0jRHAX4lPJi8DG1Bd4ikAp3vHHgu86D12fibPRkREhr2zqC6Z3AMcUuW2g8DBwA+9v1cC0zJ6PiIiMozNBvqx5HAhsJj4hPKmd7vc2z5u21XAkHf/U1k9IRERGd7+iCWGh7HRJ/YG+qhcopmH9d36ZRXb3kOx34+IiLSxDmARsAbYznn841SXeAAmUN4E211WA1uk+zRERKSZbAxsFvL4DwhPJOsoTTwAM4BlEdufklLcIiLSYrqA2ylPJBdTnngA9qO8OfbvUBWbiIgkMAl4hmIiuZ7SkQuCTnG2XQPMzCRKERFpKTOBN7DhcNx+PPMitvdLRJ/OIjgREWlNo7FOplA58YA1OBARSV133gFIanqd+yu92xUx269KMRYREWlDRwKz8g5CREREREREREREREREREREREREREREREREREREREREREREREREREREREREREREREREREREREREREREREREREREREREREREREREWsF4YKO8gxARkfawH7AEWANsl3MsIiLS4k4ABoCCtzwFjMk1IhERyVRXhuf6EHBN4JwbAZ3A3RnG0UruBo4BNgHeBt7INxwRkeFjV6CPYknHXfqAbfILram9TulruRT4OXAyek1FpI1NAl4mPOn4yy25RdfcNgE+CdwALKL8dX0duA44CZieT4giItk7n/ikUwDWATvlFWAL2QE4DUvkb1L+Or8MXAEchyUtEZGWsxXQT+XEUwB+llOMraoT2Bk4A7gdWEX5a/4UcBFwJNCTT5giIo11FZUTznL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kaamxCNJ9AGXAq/mHYiINC9VtUlSn847ABFpbirxNL/giNJhI0y7j4X92Ki03jcXuBA4Bn12RETa1paU9k3YO2Sbhc76LwXWjaJ0CJKPRZxnKqWjIDRiZGAREWky2wPXUpp47sKak3ZjA4Z+LbD+eWwK4bHYtNcXBdY/ho33NiFwrsMC252b2rMSEZFhy50t0V2GsImyHoxYXwC+GLMuLLFMAJZ463qB3dJ7WiLSyv4fXOqDdFAVLzUAAAAASUVORK5CYII=\n",
      "text/plain": [
       "<IPython.core.display.Image object>"
      ]
     },
     "metadata": {
      "image/png": {
       "height": 105,
       "width": 207
      }
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "for thisSpanner in splitTuple.spannerList:\n",
    "    s.insert(0, thisSpanner)\n",
    "s.show()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {
    "collapsed": true,
    "sphinx_links": {
     "any": true
    }
   },
   "source": [
    "### Showing and Writing\n",
    "\n",
    "The two last methods are almost certainly the most important: `.show()` and `.write()`.  We've been using `.show()` throughout the User's Guide, so it's familiar.  It usually takes a single argument which is the format (default is `'musicxml'` except on IPython where it is `'musicxml.png'`.  `.write()` by contrast writes out the file to disk.  The first argument is again the format.  The second argument, optional, is the filename with path.  If omitted then a temporary file is written (and the filename is returned).\n",
    "\n",
    "We'll see enough about `.show()` and `.write()` later, so that's enough for now on this long chapter.  Let's return to the `.beat` related function in :ref:`Chapter 14, Time Signatures <usersGuide_14_timeSignatures>`."
   ]
  }
 ],
 "metadata": {
  "anaconda-cloud": {},
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.7.2"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 1
}
